<template>
  <div class="add-edu">
    <header>添加教育经历</header>

    <div class="middle">
      <ul>
        <li><input class="input" placeholder="学校名称" v-model="edu.college"></li>
        <li><input class="input" placeholder="所学专业" v-model="edu.professionalClassification"></li>
        <li><input class="input" placeholder="入学时间" v-model="edu.admissionTime"></li>
        <li><input class="input" placeholder="毕业时间" v-model="edu.graduationTime"></li>
        <li>
          <select v-model="edu.edu">
            <option value="初中">初中</option>
            <option value="中技">中技</option>
            <option value="高中">高中</option>
            <option value="中专">中专</option>
            <option value="大专">大专</option>
            <option value="本科">本科</option>
            <option value="硕士">硕士</option>
            <option value="MBA">MBA</option>
            <option value="EMBA">EMBA</option>
            <option value="博士">博士</option>
            <option value="其他">其他</option>
          </select>
        </li>
      </ul>
      <div class="add-button">
        <button type="button" @click="add">确 定</button>
      </div>
    </div>

    <footer>中移（成都）产业研究院</footer>
  </div>
</template>

<script>
  export default {
    name: "AddEdu",
    data() {
      return {
        edu: {}
      }
    },
    created() {

    },
    methods: {
      add() {
        this.$http.post(this.$config.edu_exp_uri, this.edu).then(resp => {
          this.$router.push({"path": "/info"});
        });
      },
      init() {
        if (this.$route.params.id) {
          this.$http.get(this.$config.edu_exp_uri + "/" + this.$route.params.id).then(resp => {
            this.eduList = resp.body
          });
        }

        console.log(this.$route.params.id);
      }
    }
  }
</script>

<style scoped>
  * {
    margin: 0;
    padding: 0;
  }

  li {
    list-style-type: none;
  }

  body {
    font-family: 微软雅黑;
    font-size: 14px;
  }

  a {
    text-decoration: none;
    color: #595959;
  }

  a:hover {
    text-decoration: underline;
  }

  header {
    width: 100%;
    height: 50px;
    line-height: 50px;
    text-align: center;
    background-color: #1389D3;
    color: #FFFFFF;
    position: fixed;
    left: 0px;
    top: 0px;
  }

  .middle input {
    font-family: 微软雅黑;
    width: 99%;
    height: 40px;
    line-height: 40px;
    border: none;
    margin-bottom: 10px;
    padding-left: 1%;
  }

  .middle select {
    font-family: 微软雅黑;
    width: 99%;
    height: 40px;
    line-height: 40px;
    border: none;
    margin-bottom: 10px;
    color: #9F9F9F;
  }

  .middle {
    margin-top: 80px;
  }

  .middle, .middle ul, .middle ul li {
    width: 100%;
    overflow: hidden;
    text-align: center;
  }

  .add-button button {
    width: 90%;
    height: 40px;
    line-height: 40px;
    color: #FFFFFF;
    background-color: #1389D3;
    border: none;
    text-align: center;
    border-radius: 4px;
    font-family: 微软雅黑;
    margin-top: 40px;
  }

  .add-button button {
    width: 90%;
    height: 40px;
    line-height: 40px;
    color: #FFFFFF;
    background-color: #1389D3;
    border: none;
    text-align: center;
    border-radius: 4px;
    font-family: 微软雅黑;
    margin-top: 40px;
  }

  footer {
    width: 100%;
    height: 60px;
    line-height: 60px;
    text-align: center;
    color: #595959;
    margin-top: 30px;
  }

</style>
